{include file='common/head' /}
　　<script src="__LAYUI__/jq.js"></script>
    <body>
        <div class="x-nav">
          <span class="layui-breadcrumb">
              <a><cite>签到管理</cite></a>
              <a><cite>打卡列表</cite></a>
          </span>
          <a class="layui-btn layui-btn-small" style="line-height:1.6em;margin-top:3px;float:right" onclick="location.reload()" title="刷新">
            <i class="layui-icon layui-icon-refresh" style="line-height:30px"></i></a>
        </div>
        <div class="layui-fluid">
            <div class="layui-row layui-col-space15">
                <div class="layui-col-md12">
                    <div class="layui-card">
                        <div class="layui-card-body ">
                            <form class="layui-form layui-col-space5">
                                <div class="layui-inline layui-show-xs-block">
                                    <input type="text" name="nickname"  placeholder="用户名" autocomplete="off" class="layui-input" value="{$get.nickname|default=''}">
                                </div>
                                <div class="layui-inline layui-show-xs-block">
                                    <input type="text" name="days"  placeholder="已连续打卡多少天" autocomplete="off" class="layui-input" value="{$get.days|default=''}">
                                </div>
                                <div class="layui-inline layui-show-xs-block">
                                    <input class="layui-input"  autocomplete="off" placeholder="打卡时间开始" name="start" id="start" value="{$get.start|default=''}">
                                </div>
                                <div class="layui-inline layui-show-xs-block">
                                    <input class="layui-input"  autocomplete="off" placeholder="打卡时间截止" name="end" id="end" value="{$get.end|default=''}">
                                </div>
                                <!-- 分页数据 -->
                                <div class="layui-inline layui-show-xs-block" style="width: 150px;">
                                    <select name="limit" lay-verify="" lay-search>
                                        <option value="" selected>分页数据</option>
                                        <option value="5" {if condition="$get['limit'] == 5"}selected{/if}>5条</option>
                                        <option value="10" {if condition="$get['limit'] == 10"}selected{/if}>10条</option>
                                        <option value="15" {if condition="$get['limit'] == 15"}selected{/if}>15条</option>
                                        <option value="20" {if condition="$get['limit'] == 20"}selected{/if}>20条</option>
                                    </select>
                                </div>

                                <div class="layui-inline layui-show-xs-block">
                                    <button class="layui-btn"  lay-submit="" lay-filter="sreach"><i class="layui-icon">&#xe615;</i></button>
                                </div>
                                <span style="float: right;">共有数据：{$count} 条</span>
                            </form>
                        </div>
                        <div class="layui-card-body layui-table-body layui-table-main">
                            <table class="layui-table layui-form">
                                <thead>
                                <tr>
                                    <th style="text-align: center;">用户名称</th>
                                    <th style="text-align: center;">打卡奖励</th>
                                    <th style="text-align: center;">打卡时间</th>
                                    <th style="text-align: center;">已连续打卡天数</th>
                                </tr>
                                </thead>
                            </table>
                            <div id="tableScrollBox" style="max-height: calc(100vh - 300px);overflow: auto;">
                                <table class="layui-table layui-form">
                                    <tbody>
                                        {foreach $signFindsData as $val}
                                            <tr>
                                                <th style="text-align: center;">{$val['nickname']}</th>
                                                <th style="text-align: center;">{$val['reward']}</th>
                                                <th style="text-align: center;">{:date('Y-m-d H:i:s',$val['add_time'])}</th>
                                                <th style="text-align: center;">{$val['days']}</th>
                                            </tr>
                                        {/foreach}
                                    </tbody>
                                </table>
                            </div>
                            <div class="layui-card-body ">
                                <div class="page">
                                    {$page}
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </body>
    <script>
      layui.use(['form','laydate'], function(){
          var laydate = layui.laydate;
          var  form = layui.form;

          //执行一个laydate实例
          laydate.render({
              elem: '#start' //指定元素
          });

          //执行一个laydate实例
          laydate.render({
              elem: '#end' //指定元素
          });

        // 监听全选
        form.on('checkbox(checkall)', function(data){
          if(data.elem.checked){
            $('tbody input').prop('checked',true);
          }else{
            $('tbody input').prop('checked',false);
          }
          form.render('checkbox');
        });
      });
    </script>
{include file='common/copyCode' /}
{include file='common/scroll' /}
{include file='common/footer' /}